package aygx.automatic;

import aygx.automatic.enrity.User;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;

/**
 * @author 暗影孤星
 * @date 2020/10/27 22:49
 * @explanation
 */
@SpringBootApplication
public class AutomaticApplication {

    public static void main(String[] args) {
        ConfigurableApplicationContext applicationContext = SpringApplication.run(AutomaticApplication.class, args);
        System.out.println(applicationContext.getBean("user1", User.class));
        System.out.println(applicationContext.getBean("user2", User.class));
        System.out.println(applicationContext.getBean("user3", User.class));
    }
}
